<template>
	<view class="content">
		<view class="padding" style="color: #FFFFFF; width: 100vw;">
			<view class="" style="margin: 0 auto; width: 100%; text-align: center;">
				<text class="t-bold" style="width: 100%; text-align: center; font-size: 35rpx; margin: 0 auto;">{{ data.title }}</text>
			</view>
			<rich-text :nodes="data.content" style="color: #CCCCCC;" class="margin"></rich-text>
		</view>
	</view>
</template>

<script>
export default {
	data() {
		return {
			id: '',
			data: {},
		};
	},
	onShow() {},
	onLoad(e) {
		e && (this.id = e.id);
		uni.setNavigationBarTitle({
			title: '最新资讯',
		});
		this.getArticles(e.id);
	},
	methods: {
		async getArticles(zid) {
			let obj = {
				// uid: uni.getStorageSync("uid"),
				zid,
			};
			const res = await this.$u.post('api/car/information', obj, {});
			if (!res.code) return uni.$showMsg();
			this.data = res.data;
			console.log('res >>  ', res);
		},
	},
};
</script>

<style lang="scss" scoped>
.content {
	width: 100vw;
	height: 100vh;
	overflow: scroll;
}
</style>
